package com.bestcem.xm.ticket.service.convert;

import com.bestcem.xm.ticket.controller.param.NotificationParam;
import com.bestcem.xm.ticket.controller.vo.NotificationVO;
import com.bestcem.xm.ticket.entity.mongo.Notification;
import org.mapstruct.Mapper;

/**
 * @author zq.ding <zq.ding@idiaoyan.com>
 * @version v1.0
 * @date 2021/8/23 14:56
 */
@Mapper(componentModel = "spring")
public interface TicketNotificationMapper {

    /**
     * entity转换为vo
     *
     * @param notification 实体类
     * @return vo
     */
    NotificationVO entity2Vo(Notification notification);

    Notification.Rule ruleToEntityRule(NotificationParam.Rule rule);

    Notification.Way wayToEntityWay(NotificationParam.Way way);
}